package com.qf.wangqing.sportsnews.callback;

import com.qf.wangqing.sportsnews.bean.RecommendRootEntity;
import com.qf.wangqing.sportsnews.bean.newsbean.NewsTitleEntity;
import com.qf.wangqing.sportsnews.bean.newstitletype2.TitleCommentRoot;
import com.qf.wangqing.sportsnews.bean.newstitletype2.TitleCommentSize;
import com.qf.wangqing.sportsnews.bean.newstitletype2.TitleRecommendRoot;
import com.qf.wangqing.sportsnews.bean.newstitletype2.TitleViewRoot;
import com.qf.wangqing.sportsnews.bean.newstitletype4.TitleRoot;

import java.util.Map;

import retrofit2.Call;
import retrofit2.http.GET;
import retrofit2.http.Query;
import retrofit2.http.QueryMap;

/**
 * Created by wuyang on 2016/12/15.
 */

public interface NewsServive {
    @GET("http://api.lifxapi.com/tiyu/rest/channel/list?version=0&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11&format=json&app_id=4&is_emulator=false")
    Call<NewsTitleEntity> getChannels();
    @GET("http://api.lifxapi.com/tiyu/rest/content/list?channel_id=0&contest_flag=true&data_version=397.3&banner_flag=true&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11&format=json&app_id=4&is_emulator=false")
    Call<RecommendRootEntity> getRecommendData();
    @GET("http://api.lifxapi.com/tiyu/rest/content/list?contest_flag=true&data_version=397.3&banner_flag=true&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11")
    Call<RecommendRootEntity> getRecommendRoot(@Query("channel_id")int id, @Query("format")String json, @Query("app_id")String appid, @Query("is_emulator")String isfalse,@QueryMap Map<String,String> map);
    @GET("http://api.lifxapi.com/tiyu/rest/content/topic?code=865682026799303&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11")
    Call<TitleRoot> getType4(@Query("id")String link,@Query("format")String json,@Query("app_id")String appid,@Query("is_emulator")String isfalse);
    @GET("http://api.lifxapi.com/tiyu/rest/content/view?code=865682026799303&s_channel_id=-1&comment=true&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11")
    Call<TitleViewRoot> getType2View(@Query("id")String link,@Query("format")String json,@Query("app_id")String appid,@Query("is_emulator")String isfalse);
    @GET("http://api.lifxapi.com/tiyu/rest/content/recommend?&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11")
    Call<TitleRecommendRoot> getType2Recommend(@Query("id")String link,@Query("format")String json,@Query("app_id")String appid,@Query("is_emulator")String isfalse);
    @GET("http://api.lifxapi.com/tiyu/rest/comment/num?dashboard_type=10&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11")
    Call<TitleCommentSize> getCommentSize(@Query("dashboard_data") int dashboard_data,@Query("format")String json,@Query("app_id")String appid,@Query("is_emulator")String isfalse);

//    http://api.lifxapi.com/tiyu/rest/comment/list?dashboard_id=49891474&limit=20&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11&format=json&app_id=4&is_emulator=false
    @GET("http://api.lifxapi.com/tiyu/rest/comment/list?&limit=20&machine_code=865682026799303&client=key%3ATiyuForAndroid&version=2.11")
    Call<TitleCommentRoot> getComments(@Query("dashboard_id") int dashboard_id, @Query("format")String json, @Query("app_id")String appid, @Query("is_emulator")String isfalse);
}
